package com.olap.starter.mapper;

import com.olap.starter.pojo.OnlineDictData;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * <p>
 * 字典数据表 Mapper 接口
 * </p>
 *
 * @author WBG
 * @since 2022-11-28
 */

public interface OnlineDictDataMapper extends BaseMapper<OnlineDictData> {

    @Select("SELECT DICT_CODE,DICT_SORT,DICT_VALUE,DICT_LABEL,DICT_TYPE,CSS_CLASS FROM SYS_DICT_DATA  WHERE DICT_TYPE in(SELECT DICT_TYPE FROM SYS_DICT_TYPE  WHERE DICT_TYPE like 'online%' or SOURCE_TYPE = 'online') order by DICT_TYPE,DICT_SORT")
    List<OnlineDictData> listOnline();
}
